Class DlgList extends Dlg
var doBack;
var body;
function DlgList(items,doBack){
	this.doBack=doBack;
	var h=items.length*70;
	if(items.length>12) h=12.5*70;
	this.addChild([
		[{dim:"body",pos:["c","c",500,h+2],bg:["#fff","#eee",6],mask:true,scroll:true,relative:1}]
	]);
	for(var i=0;i<items.length;i++){
		var text=items[i];
		this.body.addChild([
			[Button,{id:i,w:"f",h:70,type:3,bg:["#fff",i==0?null:["#eee"]]},
				[[text,"#000",20],{pos:["c","c"]}]
			]
		]);
	}
}
public function alignLeft(){
	for(var i=0;i<this.body.children.length;i++){
		var button=this.body.children[i];
		var label=button.children[0];
		label.setX(40);
	}
}
function onButtonClick(){
	this.close();
	call(this.doBack,G.target.id);
}